New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
AC_AttitudeControl: always use smaller of slew yaw and rate max #19735
Conversation
waiting for review from @lthall |
If we could see some evidence of testing that would be great. thanks for this! |
56d286d
to
394550a
Compare
made changes, rebased and stepped through with GDB, works as expected. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry Pete, Naming variables is a pain. slew_ang_vel_yaw_max is double redundant with both slew and ang_vel.
Lets just go with:
get_slew_yaw_max_degs()
get_slew_yaw_max_rads()
slew_yaw_max_rads
I apologise for sending you around again.
394550a
to
28790d3
Compare
Merged, thanks! |
We had a error on line 581:
ardupilot/libraries/AC_AttitudeControl/AC_AttitudeControl.cpp
Line 571 in c878079
This was throwing away max slew yaw because
_ang_vel_yaw_max
defaults to zero. The same bug as was fixed in #18341This adds some new methods to get max yaw rate and uses them in attitude control and copter auto yaw. Except for the bug fix above this should be no change in behavior.